//===----------------------------------------------------------------------===//
//
// This source file is part of the Soto for AWS open source project
//
// Copyright (c) 2017-2021 the Soto project authors
// Licensed under Apache License v2.0
//
// See LICENSE.txt for license information
// See CONTRIBUTORS.txt for the list of Soto project authors
//
// SPDX-License-Identifier: Apache-2.0
//
//===----------------------------------------------------------------------===//

// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/soto-project/soto/tree/main/CodeGenerator. DO NOT EDIT.

import Foundation
import SotoCore

extension Support {
    // MARK: Enums

    // MARK: Shapes

    public struct AddAttachmentsToSetRequest: AWSEncodableShape {
        /// One or more attachments to add to the set. You can add up to three attachments per set. The size limit is 5 MB per attachment. In the Attachment object, use the data parameter to specify the contents of the attachment file. In the previous request syntax, the value for data appear as blob, which is represented as a base64-encoded string. The value for fileName is the name of the attachment, such as troubleshoot-screenshot.png.
        public let attachments: [Attachment]
        /// The ID of the attachment set. If an attachmentSetId is not specified, a new attachment set is created, and the ID of the set is returned in the response. If an attachmentSetId is specified, the attachments are added to the specified set, if it exists.
        public let attachmentSetId: String?

        public init(attachments: [Attachment], attachmentSetId: String? = nil) {
            self.attachments = attachments
            self.attachmentSetId = attachmentSetId
        }

        private enum CodingKeys: String, CodingKey {
            case attachments
            case attachmentSetId
        }
    }

    public struct AddAttachmentsToSetResponse: AWSDecodableShape {
        /// The ID of the attachment set. If an attachmentSetId was not specified, a new attachment set is created, and the ID of the set is returned in the response. If an attachmentSetId was specified, the attachments are added to the specified set, if it exists.
        public let attachmentSetId: String?
        /// The time and date when the attachment set expires.
        public let expiryTime: String?

        public init(attachmentSetId: String? = nil, expiryTime: String? = nil) {
            self.attachmentSetId = attachmentSetId
            self.expiryTime = expiryTime
        }

        private enum CodingKeys: String, CodingKey {
            case attachmentSetId
            case expiryTime
        }
    }

    public struct AddCommunicationToCaseRequest: AWSEncodableShape {
        /// The ID of a set of one or more attachments for the communication to add to the case. Create the set by calling AddAttachmentsToSet
        public let attachmentSetId: String?
        /// The AWS Support case ID requested or returned in the call. The case ID is an alphanumeric string formatted as shown in this example: case-12345678910-2013-c4c1d2bf33c5cf47
        public let caseId: String?
        /// The email addresses in the CC line of an email to be added to the support case.
        public let ccEmailAddresses: [String]?
        /// The body of an email communication to add to the support case.
        public let communicationBody: String

        public init(attachmentSetId: String? = nil, caseId: String? = nil, ccEmailAddresses: [String]? = nil, communicationBody: String) {
            self.attachmentSetId = attachmentSetId
            self.caseId = caseId
            self.ccEmailAddresses = ccEmailAddresses
            self.communicationBody = communicationBody
        }

        public func validate(name: String) throws {
            try self.validate(self.ccEmailAddresses, name: "ccEmailAddresses", parent: name, max: 10)
            try self.validate(self.ccEmailAddresses, name: "ccEmailAddresses", parent: name, min: 0)
            try self.validate(self.communicationBody, name: "communicationBody", parent: name, max: 8000)
            try self.validate(self.communicationBody, name: "communicationBody", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case attachmentSetId
            case caseId
            case ccEmailAddresses
            case communicationBody
        }
    }

    public struct AddCommunicationToCaseResponse: AWSDecodableShape {
        /// True if AddCommunicationToCase succeeds. Otherwise, returns an error.
        public let result: Bool?

        public init(result: Bool? = nil) {
            self.result = result
        }

        private enum CodingKeys: String, CodingKey {
            case result
        }
    }

    public struct Attachment: AWSEncodableShape & AWSDecodableShape {
        /// The content of the attachment file.
        public let data: Data?
        /// The name of the attachment file.
        public let fileName: String?

        public init(data: Data? = nil, fileName: String? = nil) {
            self.data = data
            self.fileName = fileName
        }

        private enum CodingKeys: String, CodingKey {
            case data
            case fileName
        }
    }

    public struct AttachmentDetails: AWSDecodableShape {
        /// The ID of the attachment.
        public let attachmentId: String?
        /// The file name of the attachment.
        public let fileName: String?

        public init(attachmentId: String? = nil, fileName: String? = nil) {
            self.attachmentId = attachmentId
            self.fileName = fileName
        }

        private enum CodingKeys: String, CodingKey {
            case attachmentId
            case fileName
        }
    }

    public struct CaseDetails: AWSDecodableShape {
        /// The AWS Support case ID requested or returned in the call. The case ID is an alphanumeric string formatted as shown in this example: case-12345678910-2013-c4c1d2bf33c5cf47
        public let caseId: String?
        /// The category of problem for the AWS Support case.
        public let categoryCode: String?
        /// The email addresses that receive copies of communication about the case.
        public let ccEmailAddresses: [String]?
        /// The ID displayed for the case in the AWS Support Center. This is a numeric string.
        public let displayId: String?
        /// The ISO 639-1 code for the language in which AWS provides support. AWS Support currently supports English ("en") and Japanese ("ja"). Language parameters must be passed explicitly for operations that take them.
        public let language: String?
        /// The five most recent communications between you and AWS Support Center, including the IDs of any attachments to the communications. Also includes a nextToken that you can use to retrieve earlier communications.
        public let recentCommunications: RecentCaseCommunications?
        /// The code for the AWS service. You can get a list of codes and the corresponding service names by calling DescribeServices.
        public let serviceCode: String?
        /// The code for the severity level returned by the call to DescribeSeverityLevels.
        public let severityCode: String?
        /// The status of the case. Valid values:    opened     pending-customer-action     reopened     resolved     unassigned     work-in-progress
        public let status: String?
        /// The subject line for the case in the AWS Support Center.
        public let subject: String?
        /// The email address of the account that submitted the case.
        public let submittedBy: String?
        /// The time that the case was created in the AWS Support Center.
        public let timeCreated: String?

        public init(caseId: String? = nil, categoryCode: String? = nil, ccEmailAddresses: [String]? = nil, displayId: String? = nil, language: String? = nil, recentCommunications: RecentCaseCommunications? = nil, serviceCode: String? = nil, severityCode: String? = nil, status: String? = nil, subject: String? = nil, submittedBy: String? = nil, timeCreated: String? = nil) {
            self.caseId = caseId
            self.categoryCode = categoryCode
            self.ccEmailAddresses = ccEmailAddresses
            self.displayId = displayId
            self.language = language
            self.recentCommunications = recentCommunications
            self.serviceCode = serviceCode
            self.severityCode = severityCode
            self.status = status
            self.subject = subject
            self.submittedBy = submittedBy
            self.timeCreated = timeCreated
        }

        private enum CodingKeys: String, CodingKey {
            case caseId
            case categoryCode
            case ccEmailAddresses
            case displayId
            case language
            case recentCommunications
            case serviceCode
            case severityCode
            case status
            case subject
            case submittedBy
            case timeCreated
        }
    }

    public struct Category: AWSDecodableShape {
        /// The category code for the support case.
        public let code: String?
        /// The category name for the support case.
        public let name: String?

        public init(code: String? = nil, name: String? = nil) {
            self.code = code
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case code
            case name
        }
    }

    public struct Communication: AWSDecodableShape {
        /// Information about the attachments to the case communication.
        public let attachmentSet: [AttachmentDetails]?
        /// The text of the communication between the customer and AWS Support.
        public let body: String?
        /// The AWS Support case ID requested or returned in the call. The case ID is an alphanumeric string formatted as shown in this example: case-12345678910-2013-c4c1d2bf33c5cf47
        public let caseId: String?
        /// The identity of the account that submitted, or responded to, the support case. Customer entries include the role or IAM user as well as the email address. For example, "AdminRole (Role) &lt;someone@example.com&gt;. Entries from the AWS Support team display "Amazon Web Services," and do not show an email address.
        public let submittedBy: String?
        /// The time the communication was created.
        public let timeCreated: String?

        public init(attachmentSet: [AttachmentDetails]? = nil, body: String? = nil, caseId: String? = nil, submittedBy: String? = nil, timeCreated: String? = nil) {
            self.attachmentSet = attachmentSet
            self.body = body
            self.caseId = caseId
            self.submittedBy = submittedBy
            self.timeCreated = timeCreated
        }

        private enum CodingKeys: String, CodingKey {
            case attachmentSet
            case body
            case caseId
            case submittedBy
            case timeCreated
        }
    }

    public struct CreateCaseRequest: AWSEncodableShape {
        /// The ID of a set of one or more attachments for the case. Create the set by using the AddAttachmentsToSet operation.
        public let attachmentSetId: String?
        /// The category of problem for the AWS Support case. You also use the DescribeServices operation to get the category code for a service. Each AWS service defines its own set of category codes.
        public let categoryCode: String?
        /// A list of email addresses that AWS Support copies on case correspondence. AWS Support identifies the account that creates the case when you specify your AWS credentials in an HTTP POST method or use the AWS SDKs.
        public let ccEmailAddresses: [String]?
        /// The communication body text that describes the issue. This text appears in the Description field on the AWS Support Center Create Case page.
        public let communicationBody: String
        /// The type of issue for the case. You can specify customer-service or technical. If you don't specify a value, the default is technical.
        public let issueType: String?
        /// The language in which AWS Support handles the case. You must specify the ISO 639-1 code for the language parameter if you want support in that language. Currently, English ("en") and Japanese ("ja") are supported.
        public let language: String?
        /// The code for the AWS service. You can use the DescribeServices operation to get the possible serviceCode values.
        public let serviceCode: String?
        /// A value that indicates the urgency of the case. This value determines the response time according to your service level agreement with AWS Support. You can use the DescribeSeverityLevels operation to get the possible values for severityCode.  For more information, see SeverityLevel and Choosing a Severity in the AWS Support User Guide.  The availability of severity levels depends on the support plan for the AWS account.
        public let severityCode: String?
        /// The title of the AWS Support case. The title appears in the Subject field on the AWS Support Center Create Case page.
        public let subject: String

        public init(attachmentSetId: String? = nil, categoryCode: String? = nil, ccEmailAddresses: [String]? = nil, communicationBody: String, issueType: String? = nil, language: String? = nil, serviceCode: String? = nil, severityCode: String? = nil, subject: String) {
            self.attachmentSetId = attachmentSetId
            self.categoryCode = categoryCode
            self.ccEmailAddresses = ccEmailAddresses
            self.communicationBody = communicationBody
            self.issueType = issueType
            self.language = language
            self.serviceCode = serviceCode
            self.severityCode = severityCode
            self.subject = subject
        }

        public func validate(name: String) throws {
            try self.validate(self.ccEmailAddresses, name: "ccEmailAddresses", parent: name, max: 10)
            try self.validate(self.ccEmailAddresses, name: "ccEmailAddresses", parent: name, min: 0)
            try self.validate(self.communicationBody, name: "communicationBody", parent: name, max: 8000)
            try self.validate(self.communicationBody, name: "communicationBody", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case attachmentSetId
            case categoryCode
            case ccEmailAddresses
            case communicationBody
            case issueType
            case language
            case serviceCode
            case severityCode
            case subject
        }
    }

    public struct CreateCaseResponse: AWSDecodableShape {
        /// The AWS Support case ID requested or returned in the call. The case ID is an alphanumeric string in the following format: case-12345678910-2013-c4c1d2bf33c5cf47
        public let caseId: String?

        public init(caseId: String? = nil) {
            self.caseId = caseId
        }

        private enum CodingKeys: String, CodingKey {
            case caseId
        }
    }

    public struct DescribeAttachmentRequest: AWSEncodableShape {
        /// The ID of the attachment to return. Attachment IDs are returned by the DescribeCommunications operation.
        public let attachmentId: String

        public init(attachmentId: String) {
            self.attachmentId = attachmentId
        }

        private enum CodingKeys: String, CodingKey {
            case attachmentId
        }
    }

    public struct DescribeAttachmentResponse: AWSDecodableShape {
        /// This object includes the attachment content and file name. In the previous response syntax, the value for the data parameter appears as blob, which is represented as a base64-encoded string. The value for fileName is the name of the attachment, such as troubleshoot-screenshot.png.
        public let attachment: Attachment?

        public init(attachment: Attachment? = nil) {
            self.attachment = attachment
        }

        private enum CodingKeys: String, CodingKey {
            case attachment
        }
    }

    public struct DescribeCasesRequest: AWSEncodableShape {
        /// The start date for a filtered date search on support case communications. Case communications are available for 12 months after creation.
        public let afterTime: String?
        /// The end date for a filtered date search on support case communications. Case communications are available for 12 months after creation.
        public let beforeTime: String?
        /// A list of ID numbers of the support cases you want returned. The maximum number of cases is 100.
        public let caseIdList: [String]?
        /// The ID displayed for a case in the AWS Support Center user interface.
        public let displayId: String?
        /// Specifies whether to include communications in the DescribeCases response. By default, communications are incuded.
        public let includeCommunications: Bool?
        /// Specifies whether to include resolved support cases in the DescribeCases response. By default, resolved cases aren't included.
        public let includeResolvedCases: Bool?
        /// The ISO 639-1 code for the language in which AWS provides support. AWS Support currently supports English ("en") and Japanese ("ja"). Language parameters must be passed explicitly for operations that take them.
        public let language: String?
        /// The maximum number of results to return before paginating.
        public let maxResults: Int?
        /// A resumption point for pagination.
        public let nextToken: String?

        public init(afterTime: String? = nil, beforeTime: String? = nil, caseIdList: [String]? = nil, displayId: String? = nil, includeCommunications: Bool? = nil, includeResolvedCases: Bool? = nil, language: String? = nil, maxResults: Int? = nil, nextToken: String? = nil) {
            self.afterTime = afterTime
            self.beforeTime = beforeTime
            self.caseIdList = caseIdList
            self.displayId = displayId
            self.includeCommunications = includeCommunications
            self.includeResolvedCases = includeResolvedCases
            self.language = language
            self.maxResults = maxResults
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.validate(self.caseIdList, name: "caseIdList", parent: name, max: 100)
            try self.validate(self.caseIdList, name: "caseIdList", parent: name, min: 0)
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 10)
        }

        private enum CodingKeys: String, CodingKey {
            case afterTime
            case beforeTime
            case caseIdList
            case displayId
            case includeCommunications
            case includeResolvedCases
            case language
            case maxResults
            case nextToken
        }
    }

    public struct DescribeCasesResponse: AWSDecodableShape {
        /// The details for the cases that match the request.
        public let cases: [CaseDetails]?
        /// A resumption point for pagination.
        public let nextToken: String?

        public init(cases: [CaseDetails]? = nil, nextToken: String? = nil) {
            self.cases = cases
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case cases
            case nextToken
        }
    }

    public struct DescribeCommunicationsRequest: AWSEncodableShape {
        /// The start date for a filtered date search on support case communications. Case communications are available for 12 months after creation.
        public let afterTime: String?
        /// The end date for a filtered date search on support case communications. Case communications are available for 12 months after creation.
        public let beforeTime: String?
        /// The AWS Support case ID requested or returned in the call. The case ID is an alphanumeric string formatted as shown in this example: case-12345678910-2013-c4c1d2bf33c5cf47
        public let caseId: String
        /// The maximum number of results to return before paginating.
        public let maxResults: Int?
        /// A resumption point for pagination.
        public let nextToken: String?

        public init(afterTime: String? = nil, beforeTime: String? = nil, caseId: String, maxResults: Int? = nil, nextToken: String? = nil) {
            self.afterTime = afterTime
            self.beforeTime = beforeTime
            self.caseId = caseId
            self.maxResults = maxResults
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 10)
        }

        private enum CodingKeys: String, CodingKey {
            case afterTime
            case beforeTime
            case caseId
            case maxResults
            case nextToken
        }
    }

    public struct DescribeCommunicationsResponse: AWSDecodableShape {
        /// The communications for the case.
        public let communications: [Communication]?
        /// A resumption point for pagination.
        public let nextToken: String?

        public init(communications: [Communication]? = nil, nextToken: String? = nil) {
            self.communications = communications
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case communications
            case nextToken
        }
    }

    public struct DescribeServicesRequest: AWSEncodableShape {
        /// The ISO 639-1 code for the language in which AWS provides support. AWS Support currently supports English ("en") and Japanese ("ja"). Language parameters must be passed explicitly for operations that take them.
        public let language: String?
        /// A JSON-formatted list of service codes available for AWS services.
        public let serviceCodeList: [String]?

        public init(language: String? = nil, serviceCodeList: [String]? = nil) {
            self.language = language
            self.serviceCodeList = serviceCodeList
        }

        public func validate(name: String) throws {
            try self.validate(self.serviceCodeList, name: "serviceCodeList", parent: name, max: 100)
            try self.validate(self.serviceCodeList, name: "serviceCodeList", parent: name, min: 0)
        }

        private enum CodingKeys: String, CodingKey {
            case language
            case serviceCodeList
        }
    }

    public struct DescribeServicesResponse: AWSDecodableShape {
        /// A JSON-formatted list of AWS services.
        public let services: [Service]?

        public init(services: [Service]? = nil) {
            self.services = services
        }

        private enum CodingKeys: String, CodingKey {
            case services
        }
    }

    public struct DescribeSeverityLevelsRequest: AWSEncodableShape {
        /// The ISO 639-1 code for the language in which AWS provides support. AWS Support currently supports English ("en") and Japanese ("ja"). Language parameters must be passed explicitly for operations that take them.
        public let language: String?

        public init(language: String? = nil) {
            self.language = language
        }

        private enum CodingKeys: String, CodingKey {
            case language
        }
    }

    public struct DescribeSeverityLevelsResponse: AWSDecodableShape {
        /// The available severity levels for the support case. Available severity levels are defined by your service level agreement with AWS.
        public let severityLevels: [SeverityLevel]?

        public init(severityLevels: [SeverityLevel]? = nil) {
            self.severityLevels = severityLevels
        }

        private enum CodingKeys: String, CodingKey {
            case severityLevels
        }
    }

    public struct DescribeTrustedAdvisorCheckRefreshStatusesRequest: AWSEncodableShape {
        /// The IDs of the Trusted Advisor checks to get the status of.   If you specify the check ID of a check that is automatically refreshed, you might see an InvalidParameterValue error.
        public let checkIds: [String]

        public init(checkIds: [String]) {
            self.checkIds = checkIds
        }

        private enum CodingKeys: String, CodingKey {
            case checkIds
        }
    }

    public struct DescribeTrustedAdvisorCheckRefreshStatusesResponse: AWSDecodableShape {
        /// The refresh status of the specified Trusted Advisor checks.
        public let statuses: [TrustedAdvisorCheckRefreshStatus]

        public init(statuses: [TrustedAdvisorCheckRefreshStatus]) {
            self.statuses = statuses
        }

        private enum CodingKeys: String, CodingKey {
            case statuses
        }
    }

    public struct DescribeTrustedAdvisorCheckResultRequest: AWSEncodableShape {
        /// The unique identifier for the Trusted Advisor check.
        public let checkId: String
        /// The ISO 639-1 code for the language in which AWS provides support. AWS Support currently supports English ("en") and Japanese ("ja"). Language parameters must be passed explicitly for operations that take them.
        public let language: String?

        public init(checkId: String, language: String? = nil) {
            self.checkId = checkId
            self.language = language
        }

        private enum CodingKeys: String, CodingKey {
            case checkId
            case language
        }
    }

    public struct DescribeTrustedAdvisorCheckResultResponse: AWSDecodableShape {
        /// The detailed results of the Trusted Advisor check.
        public let result: TrustedAdvisorCheckResult?

        public init(result: TrustedAdvisorCheckResult? = nil) {
            self.result = result
        }

        private enum CodingKeys: String, CodingKey {
            case result
        }
    }

    public struct DescribeTrustedAdvisorCheckSummariesRequest: AWSEncodableShape {
        /// The IDs of the Trusted Advisor checks.
        public let checkIds: [String]

        public init(checkIds: [String]) {
            self.checkIds = checkIds
        }

        private enum CodingKeys: String, CodingKey {
            case checkIds
        }
    }

    public struct DescribeTrustedAdvisorCheckSummariesResponse: AWSDecodableShape {
        /// The summary information for the requested Trusted Advisor checks.
        public let summaries: [TrustedAdvisorCheckSummary]

        public init(summaries: [TrustedAdvisorCheckSummary]) {
            self.summaries = summaries
        }

        private enum CodingKeys: String, CodingKey {
            case summaries
        }
    }

    public struct DescribeTrustedAdvisorChecksRequest: AWSEncodableShape {
        /// The ISO 639-1 code for the language in which AWS provides support. AWS Support currently supports English ("en") and Japanese ("ja"). Language parameters must be passed explicitly for operations that take them.
        public let language: String

        public init(language: String) {
            self.language = language
        }

        private enum CodingKeys: String, CodingKey {
            case language
        }
    }

    public struct DescribeTrustedAdvisorChecksResponse: AWSDecodableShape {
        /// Information about all available Trusted Advisor checks.
        public let checks: [TrustedAdvisorCheckDescription]

        public init(checks: [TrustedAdvisorCheckDescription]) {
            self.checks = checks
        }

        private enum CodingKeys: String, CodingKey {
            case checks
        }
    }

    public struct RecentCaseCommunications: AWSDecodableShape {
        /// The five most recent communications associated with the case.
        public let communications: [Communication]?
        /// A resumption point for pagination.
        public let nextToken: String?

        public init(communications: [Communication]? = nil, nextToken: String? = nil) {
            self.communications = communications
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case communications
            case nextToken
        }
    }

    public struct RefreshTrustedAdvisorCheckRequest: AWSEncodableShape {
        /// The unique identifier for the Trusted Advisor check to refresh. Note: Specifying the check ID of a check that is automatically refreshed causes an InvalidParameterValue error.
        public let checkId: String

        public init(checkId: String) {
            self.checkId = checkId
        }

        private enum CodingKeys: String, CodingKey {
            case checkId
        }
    }

    public struct RefreshTrustedAdvisorCheckResponse: AWSDecodableShape {
        /// The current refresh status for a check, including the amount of time until the check is eligible for refresh.
        public let status: TrustedAdvisorCheckRefreshStatus

        public init(status: TrustedAdvisorCheckRefreshStatus) {
            self.status = status
        }

        private enum CodingKeys: String, CodingKey {
            case status
        }
    }

    public struct ResolveCaseRequest: AWSEncodableShape {
        /// The AWS Support case ID requested or returned in the call. The case ID is an alphanumeric string formatted as shown in this example: case-12345678910-2013-c4c1d2bf33c5cf47
        public let caseId: String?

        public init(caseId: String? = nil) {
            self.caseId = caseId
        }

        private enum CodingKeys: String, CodingKey {
            case caseId
        }
    }

    public struct ResolveCaseResponse: AWSDecodableShape {
        /// The status of the case after the ResolveCase request was processed.
        public let finalCaseStatus: String?
        /// The status of the case when the ResolveCase request was sent.
        public let initialCaseStatus: String?

        public init(finalCaseStatus: String? = nil, initialCaseStatus: String? = nil) {
            self.finalCaseStatus = finalCaseStatus
            self.initialCaseStatus = initialCaseStatus
        }

        private enum CodingKeys: String, CodingKey {
            case finalCaseStatus
            case initialCaseStatus
        }
    }

    public struct Service: AWSDecodableShape {
        /// A list of categories that describe the type of support issue a case describes. Categories consist of a category name and a category code. Category names and codes are passed to AWS Support when you call CreateCase.
        public let categories: [Category]?
        /// The code for an AWS service returned by the DescribeServices response. The name element contains the corresponding friendly name.
        public let code: String?
        /// The friendly name for an AWS service. The code element contains the corresponding code.
        public let name: String?

        public init(categories: [Category]? = nil, code: String? = nil, name: String? = nil) {
            self.categories = categories
            self.code = code
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case categories
            case code
            case name
        }
    }

    public struct SeverityLevel: AWSDecodableShape {
        /// The code for case severity level. Valid values: low | normal | high | urgent | critical
        public let code: String?
        /// The name of the severity level that corresponds to the severity level code.  The values returned by the API differ from the values that are displayed in the AWS Support Center. For example, for the code "low", the API name is "Low", but the name in the Support Center is "General guidance". These are the Support Center code/name mappings:    low: General guidance    normal: System impaired    high: Production system impaired    urgent: Production system down    critical: Business-critical system down    For more information, see Choosing a severity in the AWS Support User Guide.
        public let name: String?

        public init(code: String? = nil, name: String? = nil) {
            self.code = code
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case code
            case name
        }
    }

    public struct TrustedAdvisorCategorySpecificSummary: AWSDecodableShape {
        /// The summary information about cost savings for a Trusted Advisor check that is in the Cost Optimizing category.
        public let costOptimizing: TrustedAdvisorCostOptimizingSummary?

        public init(costOptimizing: TrustedAdvisorCostOptimizingSummary? = nil) {
            self.costOptimizing = costOptimizing
        }

        private enum CodingKeys: String, CodingKey {
            case costOptimizing
        }
    }

    public struct TrustedAdvisorCheckDescription: AWSDecodableShape {
        /// The category of the Trusted Advisor check.
        public let category: String
        /// The description of the Trusted Advisor check, which includes the alert criteria and recommended operations (contains HTML markup).
        public let description: String
        /// The unique identifier for the Trusted Advisor check.
        public let id: String
        /// The column headings for the data returned by the Trusted Advisor check. The order of the headings corresponds to the order of the data in the Metadata element of the TrustedAdvisorResourceDetail for the check. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.
        public let metadata: [String]
        /// The display name for the Trusted Advisor check.
        public let name: String

        public init(category: String, description: String, id: String, metadata: [String], name: String) {
            self.category = category
            self.description = description
            self.id = id
            self.metadata = metadata
            self.name = name
        }

        private enum CodingKeys: String, CodingKey {
            case category
            case description
            case id
            case metadata
            case name
        }
    }

    public struct TrustedAdvisorCheckRefreshStatus: AWSDecodableShape {
        /// The unique identifier for the Trusted Advisor check.
        public let checkId: String
        /// The amount of time, in milliseconds, until the Trusted Advisor check is eligible for refresh.
        public let millisUntilNextRefreshable: Int64
        /// The status of the Trusted Advisor check for which a refresh has been requested:     none: The check is not refreshed or the non-success status exceeds the timeout    enqueued: The check refresh requests has entered the refresh queue    processing: The check refresh request is picked up by the rule processing engine    success: The check is successfully refreshed    abandoned: The check refresh has failed
        public let status: String

        public init(checkId: String, millisUntilNextRefreshable: Int64, status: String) {
            self.checkId = checkId
            self.millisUntilNextRefreshable = millisUntilNextRefreshable
            self.status = status
        }

        private enum CodingKeys: String, CodingKey {
            case checkId
            case millisUntilNextRefreshable
            case status
        }
    }

    public struct TrustedAdvisorCheckResult: AWSDecodableShape {
        /// Summary information that relates to the category of the check. Cost Optimizing is the only category that is currently supported.
        public let categorySpecificSummary: TrustedAdvisorCategorySpecificSummary
        /// The unique identifier for the Trusted Advisor check.
        public let checkId: String
        /// The details about each resource listed in the check result.
        public let flaggedResources: [TrustedAdvisorResourceDetail]
        public let resourcesSummary: TrustedAdvisorResourcesSummary
        /// The alert status of the check: "ok" (green), "warning" (yellow), "error" (red), or "not_available".
        public let status: String
        /// The time of the last refresh of the check.
        public let timestamp: String

        public init(categorySpecificSummary: TrustedAdvisorCategorySpecificSummary, checkId: String, flaggedResources: [TrustedAdvisorResourceDetail], resourcesSummary: TrustedAdvisorResourcesSummary, status: String, timestamp: String) {
            self.categorySpecificSummary = categorySpecificSummary
            self.checkId = checkId
            self.flaggedResources = flaggedResources
            self.resourcesSummary = resourcesSummary
            self.status = status
            self.timestamp = timestamp
        }

        private enum CodingKeys: String, CodingKey {
            case categorySpecificSummary
            case checkId
            case flaggedResources
            case resourcesSummary
            case status
            case timestamp
        }
    }

    public struct TrustedAdvisorCheckSummary: AWSDecodableShape {
        /// Summary information that relates to the category of the check. Cost Optimizing is the only category that is currently supported.
        public let categorySpecificSummary: TrustedAdvisorCategorySpecificSummary
        /// The unique identifier for the Trusted Advisor check.
        public let checkId: String
        /// Specifies whether the Trusted Advisor check has flagged resources.
        public let hasFlaggedResources: Bool?
        public let resourcesSummary: TrustedAdvisorResourcesSummary
        /// The alert status of the check: "ok" (green), "warning" (yellow), "error" (red), or "not_available".
        public let status: String
        /// The time of the last refresh of the check.
        public let timestamp: String

        public init(categorySpecificSummary: TrustedAdvisorCategorySpecificSummary, checkId: String, hasFlaggedResources: Bool? = nil, resourcesSummary: TrustedAdvisorResourcesSummary, status: String, timestamp: String) {
            self.categorySpecificSummary = categorySpecificSummary
            self.checkId = checkId
            self.hasFlaggedResources = hasFlaggedResources
            self.resourcesSummary = resourcesSummary
            self.status = status
            self.timestamp = timestamp
        }

        private enum CodingKeys: String, CodingKey {
            case categorySpecificSummary
            case checkId
            case hasFlaggedResources
            case resourcesSummary
            case status
            case timestamp
        }
    }

    public struct TrustedAdvisorCostOptimizingSummary: AWSDecodableShape {
        /// The estimated monthly savings that might be realized if the recommended operations are taken.
        public let estimatedMonthlySavings: Double
        /// The estimated percentage of savings that might be realized if the recommended operations are taken.
        public let estimatedPercentMonthlySavings: Double

        public init(estimatedMonthlySavings: Double, estimatedPercentMonthlySavings: Double) {
            self.estimatedMonthlySavings = estimatedMonthlySavings
            self.estimatedPercentMonthlySavings = estimatedPercentMonthlySavings
        }

        private enum CodingKeys: String, CodingKey {
            case estimatedMonthlySavings
            case estimatedPercentMonthlySavings
        }
    }

    public struct TrustedAdvisorResourceDetail: AWSDecodableShape {
        /// Specifies whether the AWS resource was ignored by Trusted Advisor because it was marked as suppressed by the user.
        public let isSuppressed: Bool?
        /// Additional information about the identified resource. The exact metadata and its order can be obtained by inspecting the TrustedAdvisorCheckDescription object returned by the call to DescribeTrustedAdvisorChecks. Metadata contains all the data that is shown in the Excel download, even in those cases where the UI shows just summary data.
        public let metadata: [String]
        /// The AWS region in which the identified resource is located.
        public let region: String?
        /// The unique identifier for the identified resource.
        public let resourceId: String
        /// The status code for the resource identified in the Trusted Advisor check.
        public let status: String

        public init(isSuppressed: Bool? = nil, metadata: [String], region: String? = nil, resourceId: String, status: String) {
            self.isSuppressed = isSuppressed
            self.metadata = metadata
            self.region = region
            self.resourceId = resourceId
            self.status = status
        }

        private enum CodingKeys: String, CodingKey {
            case isSuppressed
            case metadata
            case region
            case resourceId
            case status
        }
    }

    public struct TrustedAdvisorResourcesSummary: AWSDecodableShape {
        /// The number of AWS resources that were flagged (listed) by the Trusted Advisor check.
        public let resourcesFlagged: Int64
        /// The number of AWS resources ignored by Trusted Advisor because information was unavailable.
        public let resourcesIgnored: Int64
        /// The number of AWS resources that were analyzed by the Trusted Advisor check.
        public let resourcesProcessed: Int64
        /// The number of AWS resources ignored by Trusted Advisor because they were marked as suppressed by the user.
        public let resourcesSuppressed: Int64

        public init(resourcesFlagged: Int64, resourcesIgnored: Int64, resourcesProcessed: Int64, resourcesSuppressed: Int64) {
            self.resourcesFlagged = resourcesFlagged
            self.resourcesIgnored = resourcesIgnored
            self.resourcesProcessed = resourcesProcessed
            self.resourcesSuppressed = resourcesSuppressed
        }

        private enum CodingKeys: String, CodingKey {
            case resourcesFlagged
            case resourcesIgnored
            case resourcesProcessed
            case resourcesSuppressed
        }
    }
}
